﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace AB_SD_MockProject
{
    public partial class MasterPage : System.Web.UI.MasterPage
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void cmdLogout_Click(object sender, EventArgs e)
        {
            if (Request.Cookies["CurrentUser"] != null || Request.Cookies["IsSuper"] != null)
            {
                Response.Cookies["CurrentUser"].Expires = DateTime.Now.AddDays(-1);
                Response.Cookies["IsSuper"].Expires = DateTime.Now.AddDays(-1);
            }
            Session.Clear();
            Response.Redirect("Login.aspx");          
        }
    }
}